package com.wjh.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.wjh.pojo.Menu;
import org.apache.ibatis.annotations.Param;

import java.util.List;


/**
 * 菜单表(Menu)表数据库访问层
 *
 * @author makejava
 * @since 2023-03-19 17:38:48
 */
public interface MenuMapper extends BaseMapper<Menu> {

    /**
     * 根据Id查询对应的权限
     * @param id
     * @return
     */
    List<String> selectPermsByUserId(@Param("userId") Integer id);

    List<Menu> selectAllRouterMenu();

    List<Menu> selectRouterMenuTreeByUserId(@Param("userId")Integer userId);
}
